﻿using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Bot.Domain.BotImport
{
    public class ImportResult
    {
        [JsonIgnore]
        public int Processed { get; set; }
        [JsonIgnore]
        public int Total { get; set; }
        [JsonConverter(typeof(StringEnumConverter))]
        [JsonProperty(PropertyName = "status")]
        public EnumImportHandleStatus Status { get; set; }
        [JsonProperty(PropertyName = "errorMessage", NullValueHandling = NullValueHandling.Ignore)]
        public string ErrorMessage { get; set; }
        [JsonProperty(PropertyName = "failUrl", NullValueHandling = NullValueHandling.Ignore)]
        public string FailUrl { get; set; }
        [JsonProperty(PropertyName = "operationId", NullValueHandling = NullValueHandling.Ignore)]
        public string OperationId { get; set; }
        [JsonIgnore]
        public int ErrorCode { get; set; }
        [JsonProperty(PropertyName = "percent", NullValueHandling = NullValueHandling.Ignore)]
        public int? Percent { get; set; }
    }
}
